<%@ page contentType="text/html;charset=UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt"%>
<c:set var="ctx" value="${pageContext.request.contextPath}" />


<div class="simple-form well container">
	<c:if test="${!empty error}">
		<h4 style="color: #834313;">
			<fmt:message key="regist.active.failed" />
		</h4>
		<%-- <p>Sorry! ${error } </p> --%>
		<p>
			<a class="btn btn-primary" href="${ctx }/regist"><fmt:message
					key="regist.active.button.regist" /></a>
		</p>
	</c:if>
	<c:if test="${!empty success}">
		<h4 style="color: #834313;">
			<fmt:message key="regist.active.success" />
		</h4>
		<p>
			恭喜您，您的帐号已经激活成功，<span id="reload"></span><br/>
			如果跳转失败，请点击：<a class="color_theme" href="${ctx }/login"><fmt:message
					key="regist.active.button.login" /></a>
		</p>
	</c:if>
</div>
<script type="text/javascript">  
    var start = 5;  
    var step = -1;  
    function count() {  
        document.getElementById("reload").innerHTML = "页面将在" + start+ "秒后返回登录页面...";  
        start += step;  
        if (start <= 0) {  
            start = 5;  
            //alert(start);  
            window.location = "${ctx}/login";//重定位  
        }  
        setTimeout("count()", 1000);  
    }  
    window.onload = count;  
</script> 
